package com.aidex.common.core.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.util.ArrayList;
import java.util.List;

/**
 * Tree基类
 *
 * @author Lion Li
 */

@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class TreeEntity extends BaseEntity {

	private static final long serialVersionUID = 1L;

	/** 父ID */
	private String parentId;

	/** 所有父ID */
	private String parentIds;

	/** 本级排序号 */
	private Integer treeSort;

	/** 本级排序号和所有父级排序号 */
	private String treeSorts;

	/** 树层级 */
	private Integer treeLevel;

	/** 是否叶子节点 */
	private String treeLeaf;
	/**
	 * 子部门
	 */
	@TableField(exist = false)
	@ApiModelProperty(value = "子部门")
	private List<?> children = new ArrayList<>();

}
